package android.medicalcloud.com.yiapp.yilian.ui.view.adapter;

import android.content.Context;
import android.medicalcloud.com.yiapp.yilian.ui.fragment.OrderItemFragment;
import android.support.v4.app.Fragment;
import android.support.v4.app.FragmentManager;
import android.support.v4.app.FragmentPagerAdapter;

/**
 * Created by wanggenlin on 17-5-18.
 */
public class OrderMainPageAdapter extends FragmentPagerAdapter {

    final int PAGE_COUNT = 3;
    private String tabTitles[] = new String[]{"全部","待确认","待执行"};
    private Context context;

    public OrderMainPageAdapter(FragmentManager fm,Context context) {
        super(fm);
        this.context = context;
    }

    @Override
    public Fragment getItem(int position) {
        return OrderItemFragment.newInstance(position + 1);
    }

    @Override
    public int getCount() {
        return PAGE_COUNT;
    }
    @Override
    public CharSequence getPageTitle(int position) {
        return tabTitles[position];
    }
}
